import request2 from '@/utils/request2'
import { unionApiUrl } from '../../config'

/**
 * 项目设计月报列表
 * @param params
 * @param data
 */
export function getMonthlyReportList(params, data) {
  return request2({
    url: unionApiUrl + '/designMonthlyReport/getPageDesignMonthlyReport',
    method: 'post',
    params,
    data
  })
}

/**
 * 查看项目设计月报详情
 */
export function getMonthlyReportOne(params, data) {
  return request2({
    url: unionApiUrl + '/designMonthlyReport/getDesignMonthlyReportDetail',
    method: 'get',
    params,
    data
  })
}

/**
 * 修改设计月报
 /designMonthlyReport/updateByPrimaryKeySelective
 */
export function updateByPrimaryKeySelective(params, data) {
  return request2({
    url: unionApiUrl + '/designMonthlyReport/updateByPrimaryKeySelective',
    method: 'post',
    params,
    data
  })
}

/**
 * 添加当月设计管理工作计划
 */
export function insertNextMonthWorkPlan(params, data) {
  return request2({
    url: unionApiUrl + '/designNextMonthWorkPlan/insertSelective',
    method: 'post',
    params,
    data
  })
}

/**
 * 删除当月设计管理工作计划
 */
export function deleteNextMonthWorkPlan(params, data) {
  return request2({
    url: unionApiUrl + '/designNextMonthWorkPlan/deleteByPrimaryKey',
    method: 'post',
    params,
    data
  })
}

/**
 * 添加工程洽商联系单
 */
export function insertRegardingContact(params, data) {
  return request2({
    url: unionApiUrl + '/designRegardingContact/insertSelective',
    method: 'post',
    params,
    data
  })
}

/**
 * 删除工程洽商联系单
 */
export function deleteRegardingContact(params, data) {
  return request2({
    url: unionApiUrl + '/designRegardingContact/deleteByPrimaryKey',
    method: 'post',
    params,
    data
  })
}

/**
 * 添加深化设计成果
 */
export function addDeepenResults(params, data) {
  return request2({
    url: unionApiUrl + '/designDeepenResults/insertSelective',
    method: 'post',
    params,
    data
  })
}
/**
 * 编辑深化设计成果
 */
export function updateDeepenResults(params, data) {
  return request2({
    url: unionApiUrl + '/designDeepenResults/updateByPrimaryKeySelective',
    method: 'post',
    params,
    data
  })
}

/**
 * 项目设计月报列表统计
 */
export function getDesignMonthlyReportTotal(params, data) {
  return request2({
    url: unionApiUrl + '/designMonthlyReport/getDesignMonthlyReportTotal',
    method: 'post',
    params,
    data
  })
}

/**
 * 打印
 * @param parameter
 */
export function print(parameter) {
  return request2({
    url: unionApiUrl + '/designMonthlyReport/print',
    method: 'get',
    params: parameter
  })
}

